package ooday02;

public class Student extends Person {
    String className;
    String stuId;

    //int num;

    /*void sup(int num){
        //this.num = num;
        super.num = num;
    }*/

    //super();

    Student() {

    }

    Student(String name, int age, String address, String className, String stuId) {
//        super.name = name;
//        super.age = age;
//        super.address = address;
        super(name, age, address);

        this.className = className;
        this.stuId = stuId;
    }

    void sayHi() {
        super.sayHi();
        System.out.println("大叫好，我是" + name + "，今年" + age + "岁了，我的家乡是" + address +
                "，我的班级是" + className + "，我的学号是" + stuId);
    }

    void work() {
        System.out.println(name + "正在学习……");
    }

}
